select elm_id,
lpad(' ',(level-1) *4) || cmp_cat_Id || '-' || elm_displayName "ELM_DISPLAYNAME",
aur_root_elm_Id aut_r_id,
aux_parent_elm_Id aux_r_id,
scm_name || ' (' || scm_id ||')' scm_name,cmp_sibling_order "POS",cmp_id,
cmp_path,SYS_CONNECT_BY_PATH('[' || cmp_cat_Id || ']' || cmp_target_elm_Id,'/') "CALC_CMP_PATH" 
from (
select * from element 
join composition on cmp_target_elm_Id = elm_Id
join scheme on elm_scm_Id = scm_Id
 left join autroot on elm_Id = aur_root_elm_id
left join autindex on elm_Id = aux_child_elm_Id 
) connect by prior 
cmp_target_elm_Id = cmp_source_elm_Id  
start with cmp_source_elm_Id is null
order SIBLINGS by cmp_cat_Id, cmp_sibling_order
